<div class="form">
    <?php $form=$this->beginWidget('BActiveForm', array(
        'id'=>'tags-form',
        'enableClientValidation'=>true,
        'enableAjaxValidation'=>true,
        'clientOptions'=>array(
            'validateOnSubmit'=>true,
        )
    )); ?>
    <div class="control-group">
        <label class="control-label"><span class="require">*</span>标签名称：</label>
        <div class="controls">
            <?php echo $form->textField($model, 'tag_name'); ?>
            <?php echo $form->error($model,'tag_name'); ?>
        </div>
    </div>

    <div class="control-group">
        <div class="controls">
            <input type="submit" value="<?php echo $model->isNewRecord ? '添  加' : '修  改';?>" id="submit" class="btn btn-primary"/>
            <input type="button" value="返  回" onclick="javascript:history.back();" class="btn btn-warning"/>
        </div>
    </div>
    <?php $this->endWidget(); ?>

</div>